package com.owlsmart.bluecat.fragment;

import android.annotation.SuppressLint;
import android.os.Bundle;
import android.view.View;
import android.widget.ImageView;


import com.owlsmart.bluecat.R;
import com.owlsmart.bluecat.activity.HotMovieActivity;
import com.owlsmart.bluecat.activity.MyCollectActivity;
import com.owlsmart.bluecat.activity.WebActivity;

import butterknife.BindView;
import butterknife.OnClick;

@SuppressLint("NonConstantResourceId")
public class MyFragment extends BaseFragment {


    @BindView(R.id.img_header)
    ImageView imgHeader;

    public MyFragment() {
        // Required empty public constructor
    }

    public static MyFragment newInstance() {
        MyFragment fragment = new MyFragment();
        return fragment;
    }


    @Override
    protected int initLayout() {
        return R.layout.fragment_my;
    }

    @Override
    protected void initView() {

    }

    @Override
    protected void initDate() {


    }


    @OnClick({R.id.img_header, R.id.rl_collect, R.id.rl_skin, R.id.rl_logout, R.id.rl_owl})
    public void onClick(View view) {
        switch (view.getId()) {
            case R.id.img_header:
                showToast("批量点击生效测试1");
                break;
            case R.id.rl_collect:
                navigateTo(MyCollectActivity.class);
                break;
            case R.id.rl_owl:
                showToast("批量点击生效测试3-跳转到蓝猫视频");
                navigateTo(HotMovieActivity.class);
                break;
            case R.id.rl_skin:
                // showToast("点击跳转了...");
                String url = "https://www.tmall.com/";
                Bundle bundle = new Bundle();
                bundle.putString("url", url);
                navigateToWithBundle(WebActivity.class, bundle);
                break;
            case R.id.rl_logout:
                showToast("批量点击生效测试4");
                break;
        }
    }
}